package com.chat.datea.fragment;

import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import android.widget.ImageButton;
import android.widget.ListView;
import android.widget.TextView;

import com.chat.datea.R;
import com.chat.datea.adapter.HistoryAdapter;
import com.chat.datea.base.BaseFragment;

/**
 * Created by 王锦予 on 15/11/3.
 */
public class HistoryDetails extends BaseFragment implements View.OnClickListener, AdapterView.OnItemClickListener {
    private ImageButton find_Back;
    private TextView find_Title;
    private ListView find_Jump;
    private HistoryAdapter loderAdapter;
    @Override
    protected void initData() {
       loderAdapter = new HistoryAdapter(mActivity);
        find_Jump.setAdapter(loderAdapter);
    }



    @Override
    protected void initView() {
        find_Back = (ImageButton) view.findViewById(R.id.find_Back);
        find_Title = (TextView) view.findViewById(R.id.find_Title);
        find_Title.setText("历史播放");
        find_Back.setOnClickListener(this);
        find_Jump = (ListView) view.findViewById(R.id.find_Jump);
        find_Jump.setOnItemClickListener(this);

    }

    @Override
    protected View inflaterView(LayoutInflater inflater, ViewGroup container) {
        view = inflater.inflate(R.layout.fragment_find_songlist_jump, null);
        return view;
    }



    @Override
    public void onClick(View v) {
        switch (v.getId()){
            case R.id.find_Back:
                getActivity().getSupportFragmentManager().popBackStack();

        }
    }

    @Override
    public void onItemClick(AdapterView<?> parent, View view, int position, long id) {

    }
}
